<?php
require_once '../config.php';
require_once '../util/perm.php';
require_once '../util/Bitter.php';

$_TPL['fid'] = intval((int)$_REQUEST['fid']); 
$_TPL['stream'] = intval((int)$_REQUEST['stream']); 
$_TPL['tid'] = intval((int)$_REQUEST['tid']); 

if( !hasPerm('post.make') ) 
  return showTpl('Unauthorized');

if( $_TPL['stream'] > 0 ) 
  showTpl('NewPost');
elseif( $_TPL['fid'] > 0 )
  showTpl('NewThread');
else
  showTpl('Error');

?>
